package com.zpark.transaction.service.controller;

import com.zpark.jushanpay.common.domain.RestResponse;
import com.zpark.transaction.api.dto.QRCodeDTO;
import com.zpark.transaction.api.service.ITransactionService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * 订单交易控制层
 */
@RestController
@RequestMapping("/order")
public class TransactionController {

    @Autowired
    private ITransactionService transactionService;;

    /**
     * 创建门店二维码接口
     */
    @PostMapping("/create_storeQRCode")
    public RestResponse<String> createStoreQRCode(@RequestBody QRCodeDTO dto) {
        // 调用业务层方法实现创建门店二维码
        return RestResponse.success(transactionService.createStoreQRCode(dto));
    }
}
